﻿using System;

namespace Dsl.Ped.Common.Exceptions
{
    /// <summary>
    /// Exception that notifies that a string is invalid in a specific context.
    /// The core of the invalidity is described in the message
    /// </summary>
    public class InvalidStringException : Exception
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="InvalidStringException"/> class. 
        /// </summary>
        /// <param name="str">String value that is invalid</param>
        /// <param name="message">Reason of the invalidity</param>
        public InvalidStringException(string str, string message)
            : base(string.Format("{0} is invalid. {1}", str, message))
        {
        }
    }
}
